<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="utf-8">
    <title>商品列表</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link rel="stylesheet" th:href="@{/assets/framework/lib/layui-v2.8.17/css/layui.css}" media="all">
    <link rel="stylesheet" th:href="@{/assets/framework/css/public.css}" media="all">
    <style>
        .good-pic {
            width: 100px;
            height: 100px;
            border: 1px solid #ccc;
        }
        .layui-table-body .layui-table-cell {
            height: 110px;
            line-height: 110px;
        }
    </style>
</head>
<body>
<div class="layuimini-container">
    <div class="layuimini-main">

        <fieldset class="table-search-fieldset">
            <legend>查询条件</legend>
            <div style="margin: 10px 10px 10px 10px">
                <form id="search-form" class="layui-form layui-form-pane" action="">
                    <div class="layui-form-item">
                        <div class="layui-inline">
                            <label class="layui-form-label">商品编号</label>
                            <div class="layui-input-inline">
                                <input type="text" name="id" autocomplete="off" class="layui-input">
                            </div>
                        </div>
                        <div class="layui-inline">
                            <label class="layui-form-label">商品名称</label>
                            <div class="layui-input-inline">
                                <input type="text" name="name" autocomplete="off" class="layui-input">
                            </div>
                        </div>

                        <div class="layui-inline">
                            <button type="submit" class="layui-btn layui-btn-primary"  lay-submit lay-filter="search-btn"><i class="layui-icon"></i>搜索</button>
                            <button type="button" id="reset-button" class="layui-btn layui-btn-primary">重置</button>
                        </div>
                    </div>
                </form>
            </div>
        </fieldset>



        <script type="text/html" id="toolbar">
            <div class="layui-btn-container">
                <button class="layui-btn layui-btn-normal layui-btn-sm data-add-btn" lay-event="add"> 添加 </button>
                <button class="layui-btn layui-btn-sm layui-btn-danger data-delete-btn" lay-event="delete"> 删除 </button>
            </div>
        </script>



        <script type="text/html" id="row-toolbar">
            <a class="layui-btn layui-btn-normal layui-btn-xs data-count-edit" lay-event="edit">编辑</a>
            <a class="layui-btn layui-btn-xs layui-btn-danger data-count-delete" lay-event="delete">删除</a>
        </script>
        <table class="layui-hide" id="tbl" lay-filter="tbl"></table>
        <script type="text/html" id="is_take_off">
            <input type="checkbox" name="isTakeOff" value="{{= d.id }}" title="是|否" lay-skin="switch"
                   lay-filter="is_take_off" {{=d.isTakeOff? "checked" : "" }}>
        </script>

        <script type="text/html" id="is_best_seller">
            <input type="checkbox" name="isBestSeller" value="{{= d.id }}" title="是|否" lay-skin="switch"
                   lay-filter="is_best_seller" {{=d.isBestSeller? "checked" : "" }}>
        </script>

        <script type="text/html" id="is_new_product">
            <input type="checkbox" name="isNewProduct" value="{{= d.id }}" title="是|否" lay-skin="switch"
                   lay-filter="is_new_product" {{=d.isNewProduct? "checked" : "" }}>
        </script>
    </div>
</div>
<script th:src="@{/assets/framework/lib/layui-v2.8.17/layui.js}" charset="utf-8"></script>
<script th:inline="javascript">
    let ctx = /*[[@{/}]]*/"";
    if (ctx.endsWith("/")){
        ctx = ctx.substring(0,ctx.length-1);
    }
</script>
<script th:src="@{/assets/good/list.js}"></script>
</body>
</html>